package cn.paul.wechatshop.entity;

import cn.paul.wechatshop.common.Const;
import cn.paul.wechatshop.utils.serializer.Date2LongSerializer;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import lombok.Data;
import org.hibernate.annotations.DynamicUpdate;
import org.hibernate.annotations.GeneratorType;

import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Transient;
import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
 * @author 徐凌峰
 * @date 2017/12/12 0012
 */
@Entity
@DynamicUpdate
@Data
public class OrderMaster {
    @Id
    private String orderId;

    private String buyerName;

    private String buyerPhone;

    private String buyerAddress;
    /**
     * 微信ID
     */
    private String buyerOpenid;

    private BigDecimal orderAmount;
    //默认值为0.新下单
    private Integer orderStatus= Const.OrderStatusEnum.NO_PAY.getCode();
    private Date createTime;

    private Date updateTime;


}
